package com.ztstkj.lzboard.app

import android.app.Application
import android.content.Intent
import cn.jpush.android.api.JPushInterface
import com.blankj.utilcode.util.DeviceUtils
import com.sscl.baselibrary.utils.DebugUtil
import com.ztstkj.lzboard.services.BootService
import com.ztstkj.lzservices.mmkvs.MmkvUtil

class MyApplication :Application(){
    override fun onCreate() {
        super.onCreate()
        //setBootService()

        JPushInterface.setDebugMode(true)
        JPushInterface.init(this)
        JPushInterface.setAlias(this,0,DeviceUtils.getAndroidID())

        DebugUtil.setDebugFlag(true)
        MmkvUtil.instance.init(this)
    }
    private fun setBootService(){
        // 启动BootService
        var intent = Intent(applicationContext,BootService::class.java)
        startService(intent)
    }
}